package com.health.trans.pojo;

import com.health.trans.kit.WriterConfig;
import com.health.trans.util.DataSourceUtil;
import lombok.Data;
import lombok.EqualsAndHashCode;


/**
 * @author nqlz
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class WriterJson extends SyncProperty{

    public <T> WriterConfig<T> getWriterConfig() {
        return new WriterConfig<T>()
                .setDataSource(DataSourceUtil.getDataSource(super.getSource()))
                .setSourceName(super.getSource());
    }
}
